<div class="row m-n">
    <div class="crumbs-bar">
        <div yb-crumbs></div>
    </div>
    <div tabset type="tab">
        <div tab heading="零件查询" active="activeFlag[0]" ng-click="changeTab(0)">
            <div class="row wrapper-y-sm">
                <div class="search-bar wrapper-none col-xs-12">
                    <div class="btn-group m-l-xs pull-right">
                        <button type="button" class="btn btn-default base-color" ng-click="search()" translate
                            translate-attr-title="刷新">
                            <i class="yb-icon ico-refresh"></i>
                        </button>
                        <button type="button" class="btn btn-default base-color" translate translate-attr-title="配置表格列"
                            ng-click="switchToolbar('ColConfig');">
                            <i class="yb-icon ico-set"></i>
                        </button>
                    </div>
                    <button class="btn-advance pull-right m-l-xs" ng-click="switchToolbar('AdvanceSearch')"
                        translate-attr-title="高级搜索" translate="高级搜索more"></button>
                    <div class="input-group pull-right clearfix" ng-style="{'width':isEN?'280px':'240px'}">
                        <input type="text" class="form-control txt-search" translate
                            translate-attr-placeholder="原零件号" ng-model="condition.sourceMaterialNo">
                        <span class="input-group-addon cursor-pointer" ng-click="search(1)" translate>搜索</span>
                    </div>
                </div>
            </div>
            <div yb-advance-search show-toolbar="toolbarConfig.showAdvanceSearch" search-data="search(1)"
                reset-data="reset()">
                <div class="advance-search m-t-sm">
                    <div class="form-group clearfix">
                        <label class="control-label"><span translate>原零件号</span>：</label>
                        <textarea ng-model="condition.sourceMaterialNosTemp" class="form-control" ng-blur="handleBlur('sourceMaterialNosTemp', $event)" translate translate-attr-placeholder="逗号分隔或者换行分隔"></textarea>
                    </div>
                    <div class="form-group clearfix">
                        <label class="control-label"><span translate>替换类型</span>：</label>
                        <select ng-model="condition.replaceCode" class="form-control"
                            ng-options="item.code as (item.name | translate) for item  in replaceCodeList">
                            <option value="" translate>请选择</option>
                        </select>
                    </div>
	

                </div>
            </div>
            <div yb-col-config show-toolbar="toolbarConfig.showColConfig" ng-model="tableConfig" col-fixed="false"
                has-check-col="true"></div>
            <div class="main-area" style="top:85px;">
                <div yb-table-fixed class="table-fixed-wrap fix-left">
                    <div class="th-scroll-x">
                        <table class="table-fixed border-none" width="{{tableConfig.scrollWidth}}">
                            <thead>
                                <tr>
                                    <th width="40" class="text-center th-check border-l-none">
                                        <div yb-check-box yb-checked="markInfo.allChecked" yb-click="selectAll()"></div>
                                    </th>
                                    <th ng-repeat="itemCol in tableConfig.tableCol track by $index" width="{{itemCol.width}}"
                                        ng-show="!!itemCol.isShow && !itemCol.isFixed">
                                        <div yb-thead-operate ng-model="itemCol" target-width="tableConfig.scrollWidth">
                                        </div>
                                    </th>
                                </tr>
                            </thead>
                        </table>
                    </div>
                    <div class="td-scroll" ng-show="dataList.length > 0">
                        <table class="table-fixed border-none" width="{{tableConfig.scrollWidth}}">
                            <tbody>
                                <tr ng-repeat="item in dataList track by $index"
                                    ng-class="{'row-selected': $index === markInfo.curMaterialRow}"
                                    ng-click="selectRow($index, 'Material')">
                                    <td width="40" class="text-center border-l-none">
                                        <div yb-check-box yb-checked="item.isChecked" yb-click="selectSingle(item)"></div>
                                    </td>
                                    <td class="spill-dots" ng-repeat="itemCol in tableConfig.tableCol track by $index"
                                        width="{{itemCol.width}}"
                                        ng-show="!!itemCol.isShow && !itemCol.isFixed"
                                        title="{{ item[itemCol.dataField]}}">
                                        <span ng-if="!itemCol.clickFn && itemCol.type != 'image'">{{item[itemCol.dataField]}}</span>
                                        <a ng-if="!itemCol.clickFn && itemCol.type == 'image' && item[itemCol.dataField]" ng-click="viewImage(imgItem)" translate
                                            ng-repeat="imgItem in item.orgImageUrlList track by $index"
                                            style="color: blue;">查看</a>
                                    </td>
                                </tr>
                            </tbody>
                        </table>
                    </div>
                    <div class="no-data w-full text-center p-t" ng-show="dataList.length === 0" translate>暂时没有数据</div>
                </div>
            </div>
            <div class="bottom-area page-bar wrapper-y-sm clearfix">
                <div yb-check-box class="m-t-xs m-r-sm" yb-checked="markInfo.allChecked" yb-check-name="全选"
                    yb-click="selectAll()"></div>
                <button class="btn btn-operate" ng-click="delData('batch')" ng-disabled="!btnPermission.materielDel"
                    translate translate-attr-title="{{!btnPermission.materielDel?'无权限执行此操作':''}}">删除</button>
                <div yb-page-info ng-model="pageInfo" yb-refresh="search()"></div>
            </div>
        </div>
    </div>
</div>
